<script type="text/javascript">

    
    jQuery(function($) {
        $('table th input:checkbox').on('click', function() {
            var that = this;
            $(this).closest('table').find('tr > td:first-child input:checkbox')
                    .each(function() {
                        this.checked = that.checked;
                        $(this).closest('tr').toggleClass('selected');
                    });
        });
        $(".help-button").popover();
        $('[data-rel=tooltip]').tooltip();
        var is_start = "{$three|getThreeField=###,'order_set','is_start'}";
        if(is_start == 1){
        var seconds = "{$three|getThreeField=###,'order_set','seconds'}";
        var t = setInterval("getOrderVoice()", seconds * 1000);
    }
    })
    var video = "{$three|getThreeField=###,'order_set','video'}";
    function getOrderVoice() {
        $.post(getUrl("Ajax/getOrder"), {
        }, function(data) {
            var src = "__APP__/Public/video/" + video + "";
            if (data > 0) {
                $("<audio id='chatAudio'><source src='" + src + "' type='audio/mpeg'></audio>").appendTo('body');
                $('#chatAudio')[0].play();
            } else {
                $('#chatAudio').remove();
            }
        })
    }
</script>
<a href="#" id="btn-scroll-up" class="btn-scroll-up btn btn-sm btn-inverse">
    <i class="icon-double-angle-up icon-only bigger-110"></i>
</a>
<input type="hidden" id="SITE_URL" value="__APP__/{$Think.MODULE_NAME}"/>
</body>
</html>
